package com.markus.code.exam.beikeP;

import java.util.Scanner;

/**
 * Author:markusZhang
 * Date:Create in 2020/9/7 15:52
 * todo:
 */
public class Main1 {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        while(scanner.hasNext()){
            String str = scanner.nextLine();
            int max = getMax(str);
            if (max == 0){
                System.out.println(str.length());
            }else{
                int num = str.length()-max+1;
                System.out.println(num);
            }
        }
    }
    private static int getMax(String str){
        int max = 0;
        StringBuffer sb = new StringBuffer();
        for (int i=0;i<str.length()/2;i++){
            sb.append(str.charAt(i));
            int len = sb.length();
            String other = str.substring(len,2*len);
            if (sb.toString().equals(other)){
                max = len;
            }
        }
        return max;
    }
}
